static colaExecStatus_t colaStubM0(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaString_t *param0;

    COLA_POP_STACK(stack, colaString_t, param0);

    r = colaServerPrintString(thread, param0);

    return r;
}

static colaExecStatus_t colaStubM1(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaString_t *param0;
    colaString_t *param1;

    COLA_POP_STACK(stack, colaString_t, param1);
    COLA_POP_STACK(stack, colaString_t, param0);

    r = colaServerRegisterSpawnableStringString(thread, param0, param1);

    return r;
}

static colaExecStatus_t colaStubM2(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaString_t *param0;

    COLA_POP_STACK(stack, colaString_t, param0);

    r = colaServerRegisterClientClassString(thread, param0);

    return r;
}

static colaExecStatus_t colaStubM3(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaInteger_t *returnV;


    returnV = COLA_STACKVAR(stack, colaInteger_t);

    r = colaServerCmdArgc(thread, returnV);

    if(r == COLA_EXEC_OK)
        stack->info.alive = 1;
    return r;
}

static colaExecStatus_t colaStubM4(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaInteger_t *param0;
    colaString_t *returnV;

    COLA_POP_STACK(stack, colaInteger_t, param0);

    returnV = COLA_STACKVAR(stack, colaString_t);

    r = colaServerCmdArgvInteger(thread, returnV, param0);

    if(r == COLA_EXEC_OK)
        stack->info.alive = 1;
    return r;
}

static colaExecStatus_t colaStubM5(colaThread_t *thread, colaExecStackVar_t *stack)
{
    colaDataReference_t *ref;
    colaExecArrayRef_t *aref;
    colaExecStatus_t r;
    colaInteger_t *param0;
    colaString_t *returnV;

    COLA_POP_STACK(stack, colaInteger_t, param0);

    returnV = COLA_STACKVAR(stack, colaString_t);

    r = colaServerCmdArgvSequencedInteger(thread, returnV, param0);

    if(r == COLA_EXEC_OK)
        stack->info.alive = 1;
    return r;
}

static colaAPIStandardMethod_t colaStubMethods[] =
{
    { colaStubM0, "Print", "value common:string" },
    { colaStubM1, "RegisterSpawnable", "value common:string value common:string" },
    { colaStubM2, "RegisterClientClass", "value common:string" },
    { colaStubM3, "CmdArgc", "" },
    { colaStubM4, "CmdArgv", "value common:integer" },
    { colaStubM5, "CmdArgvSequenced", "value common:integer" },
    { NULL },
};

static colaAPI_t colaStubAPI =
{
    colaStubMethods,
    NULL,
    NULL,
    NULL,
    NULL
};
